package com.lzp.ime

import android.inputmethodservice.InputMethodService
import android.util.Log
import android.view.View
import android.view.inputmethod.EditorInfo

class LzpIME : InputMethodService() {

    private val TAG = "LzpIME"

    override fun onCreate() {
        Log.d(TAG, "onCreate: ")
        super.onCreate()
    }

    override fun onCreateInputView(): View {
        Log.d(TAG, "onCreateInputView: ")
        return layoutInflater.inflate(R.layout.input_container, null)
    }

    override fun onCreateCandidatesView(): View {
        Log.d(TAG, "onCreateCandidatesView: ")
        return layoutInflater.inflate(R.layout.input_candidates, null)
    }

    override fun onStartInput(attribute: EditorInfo?, restarting: Boolean) {
        Log.d(TAG, "onStartInput: ")
        super.onStartInput(attribute, restarting)
    }

    override fun onStartInputView(info: EditorInfo?, restarting: Boolean) {
        Log.d(TAG, "onStartInputView: ")
        super.onStartInputView(info, restarting)
    }

    override fun onFinishCandidatesView(finishingInput: Boolean) {
        Log.d(TAG, "onFinishCandidatesView: ")
        super.onFinishCandidatesView(finishingInput)
    }

    override fun onFinishInput() {
        Log.d(TAG, "onFinishInput: ")
        super.onFinishInput()
    }

    override fun onFinishInputView(finishingInput: Boolean) {
        Log.d(TAG, "onFinishInputView: ")
        super.onFinishInputView(finishingInput)
    }

    override fun onDestroy() {
        Log.d(TAG, "onDestroy: ")
        super.onDestroy()
    }
}